package com.hutiao.snowhb.entities;

import java.util.Date;
import java.util.List;

public class SnowMM {

	private int mmid;
	
	private String openId;
	
	private WeixinUserInfo weixin;
	
	private String name;
	
	private String nickname;
	
	private String phone;
	
	private int age;
	
	private String constellation;
	
	private String introduce;
	
	private String hobby;
	
	private String photoUrl;
	
	private String photoUrlBig;
	
	private String sellDistrict;
	
	private String sellOffice;
	
	private int rank;
	
	private float starAvg;
	
	/**
	 * 显示星星的数量
	 */
	private String star;
	
	private int starCount;
	
	private int commentCount;
	
	private Date createTime;
	
	private Date updateTime;
	
	private Date lastTime;
	
	private SnowMMLocation currLocation;
	
	private List<SnowMMComment> comments;
	
	private double distance;

	public int getMmid() {
		return mmid;
	}

	public void setMmid(int mmid) {
		this.mmid = mmid;
	}

	public String getOpenId() {
		return openId;
	}

	public void setOpenId(String openId) {
		this.openId = openId;
	}

	public String getName() {
		return name;
	}

	public void setName(String name) {
		this.name = name;
	}

	public String getNickname() {
		return nickname;
	}

	public void setNickname(String nickname) {
		this.nickname = nickname;
	}

	public String getPhone() {
		return phone;
	}

	public void setPhone(String phone) {
		this.phone = phone;
	}

	public int getAge() {
		return age;
	}

	public void setAge(int age) {
		this.age = age;
	}

	public String getConstellation() {
		return constellation;
	}

	public void setConstellation(String constellation) {
		this.constellation = constellation;
	}

	public String getIntroduce() {
		return introduce;
	}

	public void setIntroduce(String introduce) {
		this.introduce = introduce;
	}

	public String getHobby() {
		return hobby;
	}

	public void setHobby(String hobby) {
		this.hobby = hobby;
	}

	public String getPhotoUrl() {
		return photoUrl;
	}

	public void setPhotoUrl(String photoUrl) {
		this.photoUrl = photoUrl;
	}

	public String getSellDistrict() {
		return sellDistrict;
	}

	public void setSellDistrict(String sellDistrict) {
		this.sellDistrict = sellDistrict;
	}

	public String getSellOffice() {
		return sellOffice;
	}

	public void setSellOffice(String sellOffice) {
		this.sellOffice = sellOffice;
	}

	public int getRank() {
		return rank;
	}

	public void setRank(int rank) {
		this.rank = rank;
	}

	public float getStarAvg() {
		return starAvg;
	}

	public void setStarAvg(float starAvg) {
		this.starAvg = starAvg;
		
		if (this.starAvg < 1) {
			star = "05";
		} else if (this.starAvg >= 1 && this.starAvg < 1.5) {
			star = "10";
		} else if (this.starAvg >= 1.5 && this.starAvg < 2) {
			star = "15";
		} else if (this.starAvg >= 2 && this.starAvg < 2.5) {
			star = "20";
		} else if (this.starAvg >= 2.5 && this.starAvg < 3) {
			star = "25";
		} else if (this.starAvg >= 3 && this.starAvg < 3.5) {
			star = "30";
		} else if (this.starAvg >= 3.5 && this.starAvg < 4) {
			star = "35";
		} else if (this.starAvg >= 4 && this.starAvg < 4.5) {
			star = "40";
		} else if (this.starAvg >= 4.5 && this.starAvg < 5) {
			star = "45";
		} else if (this.starAvg >= 5) {
			star = "50";
		}
	}

	public int getStarCount() {
		return starCount;
	}

	public void setStarCount(int starCount) {
		this.starCount = starCount;
	}

	public int getCommentCount() {
		return commentCount;
	}

	public void setCommentCount(int commentCount) {
		this.commentCount = commentCount;
	}

	public Date getCreateTime() {
		return createTime;
	}

	public void setCreateTime(Date createTime) {
		this.createTime = createTime;
	}

	public Date getUpdateTime() {
		return updateTime;
	}

	public void setUpdateTime(Date updateTime) {
		this.updateTime = updateTime;
	}

	public Date getLastTime() {
		return lastTime;
	}

	public void setLastTime(Date lastTime) {
		this.lastTime = lastTime;
	}

	public WeixinUserInfo getWeixin() {
		return weixin;
	}

	public void setWeixin(WeixinUserInfo weixin) {
		this.weixin = weixin;
	}

	public SnowMMLocation getCurrLocation() {
		return currLocation;
	}

	public void setCurrLocation(SnowMMLocation currLocation) {
		this.currLocation = currLocation;
	}

	public List<SnowMMComment> getComments() {
		return comments;
	}

	public void setComments(List<SnowMMComment> comments) {
		this.comments = comments;
	}

	public double getDistance() {
		return distance;
	}

	public void setDistance(double distance) {
		this.distance = distance;
	}

	public String getStar() {
		return star;
	}

	public void setStar(String star) {
		
		this.star = star;
	}

	public String getPhotoUrlBig() {
		return photoUrlBig;
	}

	public void setPhotoUrlBig(String photoUrlBig) {
		this.photoUrlBig = photoUrlBig;
	}
}
